The present invention is related to a method and system for implementing distributed applications in a computer network. In general, the applications are executable on any location in the network.
Computers and devices are connected via networks where applications are being processed and executed. Different architectures and programming languages for their operation are known. Conventional programming languages such as Pascal, C, or Java, do not provide any standard means for identifying location requirements. In classical distributed computer applications such dependencies are identified by the application programmer who splits the overall application into integral parts, such as xe2x80x98clientxe2x80x99 and xe2x80x98serverxe2x80x99, programs these parts separately and installs them at a required position or on a required device. Communications between those parts is provided by either message-passing, remote procedure calls or, in the case of object-oriented programming languages, by remote method invocations.
Agent-technology or mobile code programming has recently introduced another method for realizing distributed systems. The need for developing the overall application in separate parts has been removed, and replaced by simple language primitives, such as the xe2x80x98GOxe2x80x99 command, which move the application in its entirety to another location. It has been shown that this simplifies the programming of such applications since the application can be written with a single flow of control.
U.S. Pat. No. 5,603,031 describes a system and a method for distributed computation based upon the movement, execution, and interaction of processes in a network. An agent process controls its movement from one place process to another within the network by using a ticket and sends clones of the agent process to several place processes simultaneously.
This simple programming model which is used for common systems has a number of limitations. First, while a single flow of control allows simple design and implementation, it is too rigid to allow for optimizations such as the exploitation of parallelism at run-time. Further, the structure prescribes a fixed location-dependency; if the requested location is unavailable, the execution of an application must halt. This is negative since it is common that for most portions of the programming code the location at which they are executed is irrelevant. Furthermore, the simple xe2x80x98GOxe2x80x99 primitive is only usable to indicate location dependencies, and the point at which a xe2x80x98GOxe2x80x99 must be executed must be defined at compile-time.
It is an object of the present invention to provide a method and system for implementing distributed applications in a network.
It is another object of the present invention to provide more location flexibility for networks.
It is a further object of the present invention to provide a simple method for the execution of distributed applications in a network.
It is still a further object of the present invention to optimize the processes in a network.
The method and system for implementing distributed applications in a network according to claim 1 and claim 9 shows the advantage that more efficiency can be obtained, because only the necessary parts of an application are transferred and executed on relevant and suitable locations, and those should only be transferred when necessary. This optimizes transferring-, connecting- and processing-times, which implicitly reduces costs. Furthermore, the method provides enough flexibility to a runtime system to allow more freedom of action, i.e. flexible and efficient execution, and is thus a remedy to the rigid structure demanded by conventional agent-programming or mobile code. Such efficiency and flexibility cannot be achieved by conventional methods of distributed-application programming, such as client/server or traditional agent system. It is therefore an object of the invention to overcome the problems of the state of the art.
In the dependent claims various modifications of and improvements to the method for implementing distributed applications are contained.
When a location is identified by giving a location identifier which comprises for the location its definite position or a functionality required for execution at the location or a parameter which from available parameters is to be chosen optimal for the execution at the location or by giving an address where to find said location identifier, then the advantage occurs that the proposed method allows a wide range of location identification possibilities. The address of a location where to execute an application is hence no longer bound to a fixed position, but the choice of a location is herewith rendered more flexible.
The present invention makes use of additional instructions, which include an assert-command which can be used wherever it is to be effected that the subsequent instructions are executed at an identified location. No other command for the execution on another location is needed, which guarantees for simplicity, uniformity and correct execution. The xe2x80x98GOxe2x80x99 command becomes unnecessary, which is an advantage for future developments and applications.
When the instructions of an application includes different assert-conmmands, such as ASSERT, INSIST and PREFERRED, then the advantage occurs that the applications get more flexibility and freedom of action. In case of non-availability of a location for the execution of the application, a first assert-commnand type (ASSERT) indicates a location and the programs willingness to suspend its execution temporarily. A second assert-command type (INSIST), on the other hand, might terminate the application in such instances. Therefore, the process of the application doesn""t wait but rather aborts execution. A third assert-command type (PREFERRED) continues by executing the subsequent instructions at the previously used location, which has the advantage that the application carries on, even though the preferred is currently unavailable. Several assert-command types are creatable and usable for distributed applications, which shows the flexibility and adaptability of the inventive method for distributed applications in a network.
The assert-command types can point to identified locations of different locations, whereby the identified locations are choosable xe2x80x9cad libitumxe2x80x9d, which means that the identified locations are selectable without any preferences, or in the other case, the identified locations are arrangable and selectable in a predetermined preference-ordered sequence, which gives much room and flexibility to move an application. The execution of an application and the processes in a network can therewith be optimized and adapted.
A runtime system is usable to move the applications to identified locations in a network and executes the instructions. In the case of a release-command the choice of a location whereto the application is moved, is then dependent on system- and/or state conditions. This provides more freedom of action for the runtime system, which is now able to use the available resources of the network.
The invention provides a general and flexible method and system for implementing a distributed application in a network.
The present invention for implementing a distributed application in a network describes a method and system which allow the temporary assertion of position-, device- or service-dependencies and can be used in applications to describe the required location behavior abstractly and in an intuitive manner. Instructions for a computer process which are executable on different locations in the network comprising an assert-command and/or a release-command. The assert-command points to an identified location of the different locations, which effects that its subsequent instructions are to be executed at the identified location. The release-command effects that the execution of its subsequent instructions is not bound to an identified location.
The problem from the state of the art that more than one location has to be used from one application is still considered valid, whereby the positions, devices or services are not fixed according to an allocated address and even the swap times, i.e. when an application moves to another location, are not predetermined.